#ifndef STAR_H
#define STAR_H

#include "ui_browserview.h"
#include "webview.h"
#include "login.h"

#include <QtDebug>
#include <QMetaType>
#include <QObject>
#include <QMutex>
#include <QVector>
#include <QSet>
#include <QMenu>
#include <QThread>
#include <QWidget>
#include <QModelIndex>
#include <QSqlQuery>
#include <QSqlRecord>
#include <QDateTime>
#include <QSqlError>
#include <QIcon>
#include <QMessageBox>
#include <QTimer>



class starobject:public QObject{
    Q_OBJECT;
public:
    QString url;
    QString text;
    QString time;

    starobject();

};


class star:public QObject{
    Q_OBJECT;
public:
    QString net="about:blank";
    int flag=0;
    Ui::browserview *ui;
    QSqlQuery query;
    QSqlDatabase db;
    WebView *view;
    bool isadd;
    starobject *liststar[5];
    starobject *starlist[100];
    star();

    void AddStar(QString url,QString text);

    bool isAdded(QString url);
    void DeleteStar(QString url);
    QString getTime();
    void loadstar();
    void loadstar1();
    void deletenet(QString url);
public slots:
    void slotCountMessage();
    void on_button_addstar_clicked();

};

#endif // STAR_H
